package Parte2;

import java.util.Random;
import java.util.concurrent.Semaphore;



public class Principal {

	/**
	 * @param args
	 */

	
	static Semaphore parking, planta1,planta2,planta3;
	
	public static void main(String[] args) {
		planta1=new Semaphore(12);
		planta2=new Semaphore(17);
		planta3=new Semaphore(9);
		parking= new Semaphore(38);
		for(int i =0; i<1000; i++){
			Random r=new java.util.Random();
			int planta=r.nextInt(3);
			planta++;
			Coche c= new Coche(planta);
			c.start();
		}
		
	}

}
